package com.cx.caigou.request.model;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

@Data
public class AllClass {
    @NotNull(message = "添加时币别不能为空")
    @ApiModelProperty(value = "币别")
    private int currencyCode;

    @ApiModelProperty(value = "法人名称")
    private String legalPersonName;
    @NotNull(message = "添加时单号不能为空")
    @ApiModelProperty(value = "单号")
    private int requestForQuotationId;

    @ApiModelProperty(value = "询价日期")
    private Date createTime;
    @NotNull(message = "添加时询价开始时间不能为空")
    @ApiModelProperty(value = "询价开始时间")
    private Date startTime;
    @NotNull(message = "添加时询价结束时间不能为空")
    @ApiModelProperty(value = "询价结束时间")
    private Date endTime;
    @NotNull(message = "添加时法人id不能为空")
    @ApiModelProperty(value = "法人id")
    private int legalPersonId;

    @NotNull(message = "添加时询价状态不能为空")
    @ApiModelProperty(value = "询价状态")
    private int inquiryStatus;

    @ApiModelProperty(value = "报价人员")
    private String creatorName;
    @NotNull(message = "添加时是否含税不能为空")
    @ApiModelProperty(value = "是否含税")
    private int isTax;
    @NotNull(message = "添加时询价类型不能为空")
    @ApiModelProperty(value = "询价类型")
    private int type;//询价类型

//    private int inquiryQty;//询价数量

    private int spareId;//备件id
    private int supplierId;//供应商id

    @ApiModelProperty(value = "询价备件明细")
    @NotEmpty(message = "添加时询价备件明细集合不能为空")
    @Valid
    private List<SpareVo> inquiryDetailsList;

    @Valid
    @ApiModelProperty(value = "待询价供应商")
    @NotEmpty(message = "添加时供应商集合")
    private List<SupplierVo> supplierDetailsList;


}
